import request from '@/axios';
import { baseUrl } from '@/config/env';

// 新闻新增
export const newsAdd = (data) => request({
    url: baseUrl + '/news/add',
    method: 'post',
    data
})
// 新闻更新
export const newsUpdate = (data) => request({
    url: baseUrl + '/news/update',
    method: 'post',
    data
})
// 新闻删除
export const newsDelete = (id) => request({
    url: baseUrl + `/news/delete/${id}`,
    method: 'get',
})
// 新闻列表
export const newsList = (data) => request({
    url: baseUrl + `/news/list`,
    method: 'post',
    data
})
